<%--
  Created by IntelliJ IDEA.
  User: lenovo
  Date: 2018/5/3
  Time: 14:33
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=utf-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<style type="text/css">
    .keywords {
        width: 250px;
        font-family: '微软雅黑', sans-serif, serif;
    }
    .span_h{
        background-color: #eff0f1;display: block;height: 30px;
        font-size: 16px;
        line-height:30px;
    }

</style>

<div class="pageHeader">
    <form rel="pageForm" onsubmit="return navTabSearch(this);" action="<c:url value='/danger/info/list'/>" method="post">
        <div class="searchBar">
            <ul>
                <li style="float: left;line-height: 25px;width: auto">
                    <label style="width: auto;line-height: 25px;">上传时间：</label>
                    <input type="text" value="<fmt:formatDate value="${query.start}" pattern="yyyy-MM-dd"/>" readonly="readonly"
                           class="date" name="start" dateFmt="yyyy-MM-dd" style="width: 100px;">
                    <span class="limit">-</span>
                    <input type="text" value="<fmt:formatDate value="${query.end}" pattern="yyyy-MM-dd"/>" readonly="readonly"
                           class="date" name="end"  dateFmt="yyyy-MM-dd" style="width: 100px;">
                </li>
                <li style="float: left;line-height: 25px;width: auto;margin-left: 0px;">
                    <label style="width: auto;line-height: 25px;">区：</label>
                    <select class="combox" name="fjid" ref="two3" refUrl="<c:url value="/danger/jl"/>?fjid={value}"  onchange="setSelVal('fjid',this.value)">
                        <option value="" <c:if test="${query.data.fjid eq '' || query.data.fjid eq null}">selected</c:if>>请选择</option>
                        <c:forEach var="dicone" items="${dicone}">
                            <option value="${dicone.id}" <c:if test="${dicone.id eq query.data.fjid}">selected</c:if>>${dicone.name}</option>
                        </c:forEach>
                    </select>
                </li>
                <li style="float: left;line-height: 25px;width: auto;margin-left: 0px;">
                    <label style="width: auto;line-height: 25px;">街道：</label>
                    <select class="combox" name="pcsid" id="two3" ref="three3" refUrl="<c:url value="/danger/jl"/>?pcsid={value}" onchange="setSelVal('pcsid',this.value)">
                        <option value="" <c:if test="${query.data.pcsid eq '' || query.data.pcsid eq null}">selected</c:if>>请选择</option>
                        <c:forEach var="dictwo" items="${dictwo}">
                            <option value="${dictwo.id}" <c:if test="${dictwo.id eq query.data.pcsid}">selected</c:if>>${dictwo.name}</option>
                        </c:forEach>
                    </select>
                </li>
                <li style="float: left;line-height: 25px;width: auto;margin-left: 0px;">
                    <label style="width: auto;line-height: 25px;">社区：</label>
                    <select class="combox" name="sqid" id="three3">
                        <option value="" <c:if test="${query.data.sqid eq '' || query.data.sqid eq null}">selected</c:if>>请选择</option>
                        <c:forEach var="dicthree" items="${dicthree}">
                            <option value="${dicthree.id}" <c:if test="${dicthree.id eq query.data.sqid}">selected</c:if>>${dicthree.name}</option>
                        </c:forEach>
                    </select>
                </li>
                <li style="float: left;line-height: 25px;width: auto;margin-left: 0px;">
                    <label style="width: auto;line-height: 25px;">隐患类：</label>
                    <select class="combox" name="yhlb" ref="childtype" refUrl="<c:url value="/danger/childtype"/>?id={value}" onchange="setSelVal('sqid',this.value)">
                        <option value="" <c:if test="${query.data.yhlb eq '' || query.data.yhlb eq null}">selected</c:if>>请选择</option>
                        <option value="1" <c:if test="${query.data.yhlb eq 1|| query.data.yhlb eq '1'}">selected</c:if>>三合一</option>
                        <option value="2" <c:if test="${query.data.yhlb eq 2|| query.data.yhlb eq '2'}">selected</c:if>>出租房</option>
                        <option value="3" <c:if test="${query.data.yhlb eq 3|| query.data.yhlb eq '3'}">selected</c:if>>电瓶车</option>
                    </select>
                </li>
                <li style="float: left;line-height: 25px;width: auto;margin-left: 0px;">
                    <label style="width: auto;line-height: 25px;">隐患子类：</label>
                    <select class="combox" name="childtype" id="childtype">
                        <option value="" <c:if test="${query.data.childtype eq '' || query.data.childtype eq null}">selected</c:if>>请选择</option>
                        <c:forEach var="dicfour" items="${dicfour}">
                            <option value="${dicfour.childtype}" <c:if test="${dicfour.childtype eq query.data.childtype}">selected</c:if>>${dicfour.name}</option>
                        </c:forEach>
                    </select>
                </li>
                <li style="float: left;line-height: 25px;width: auto;margin-left: 0px;">
                    <label style="width: auto;line-height: 25px;">状态：</label>
                    <select class="combox" name="status" style="line-height: 25px">
                        <option value=""  >请选择</option>
                        <option value="1" <c:if test="${query.data.status eq '1'}">selected</c:if> >上报</option>
                        <option value="2" <c:if test="${query.data.status eq '2'}">selected</c:if> >未审核</option>
                        <option value="3" <c:if test="${query.data.status eq '3'}">selected</c:if> >信息不属实</option>
                        <option value="4" <c:if test="${query.data.status eq '4'}">selected</c:if> >重复上报</option>
                        <option value="5" <c:if test="${query.data.status eq '5'}">selected</c:if> >已审核</option>
                        <option value="6" <c:if test="${query.data.status eq '6'}">selected</c:if> >流转数</option>
                        <option value="7" <c:if test="${query.data.status eq '7'}">selected</c:if> >直接整改</option>
                        <option value="8" <c:if test="${query.data.status eq '8'}">selected</c:if> >处罚后整改</option>
                        <option value="9" <c:if test="${query.data.status eq '9'}">selected</c:if> >未反馈</option>
                        <option value="10" <c:if test="${query.data.status eq '10'}">selected</c:if> >街道确认</option>
                        <option value="11" <c:if test="${query.data.status eq '11'}">selected</c:if> >区确认</option>
                    </select>
                </li>
                <li style="float: left;line-height: 25px;width: auto;margin-left: 15px;">
                    <div class="buttonActive"><div class="buttonContent"><button type="submit">检索</button></div></div>
                </li>
            </ul>
            <ul>
                <li style="float: left;line-height: 25px;width: auto;margin-left: 0px;">
                    <label style="width: auto;line-height: 25px;">地址信息：</label>
                    <input type="text" name="fullAddress" value="${query.data.fullAddress}" style="width: 217px;"/>
                </li>
            </ul>
        </div>
    </form>
</div>
<div class="pageContent">
    <%--<div class="panelBar">
        <ul class="toolBar">
            <li><a class="add" href="<c:url value='/kcgl/toAdd'/>" target="dialog" mask="true" resizable="false"
                   width="900" height="600" title="新增课程"><span>新增课程</span></a></li>
            <li class="line">line</li>
            <li><a title="确实要发布这些课程吗?" target="selectedTodo" callback="callbackForPUB" rel="pubids"  postType = 'string' href="<c:url value="/kcgl/pubMore"/> " class="edit"><span>批量发布</span></a></li>
            <li class="line"></li>
            &lt;%&ndash; <li><a class="icon" href="demo/common/dwz-team.xls" target="dwzExport" targetType="navTab" title="实要导出这些记录吗?"><span>导出EXCEL</span></a></li>&ndash;%&gt;
        </ul>
    </div>--%>
    <table class="table" width="100%" layoutH="110">
        <thead>
        <tr>
            <th width="40"  align="center">序号</th>
            <th width="120" align="center">编号</th>
            <%--<th width="100">类型</th>--%>
            <th width="120"  align="center">上传时间</th>
            <th width="120"  align="center">区</th>
            <th width="120" align="center">街道</th>
            <th width="120" align="center">社区</th>
            <th width="120" align="center">隐患类别</th>
            <th width="100" align="center">状态</th>
            <th width="150"  align="center">操作</th>
        </tr>
        </thead>
        <tbody>
        <c:forEach items="${pager.list}" var="list" varStatus="state" >
            <tr>
                <td>${state.count+(pager.pageNum-1)*pager.numPerPage}</td>
                <td style="text-align: left;">${list.seqid}</td>
                <td><fmt:formatDate value="${list.createtime}" pattern="yyyy-MM-dd"/></td>
                <td>${list.fjid}</td>
                <td>${list.pcsid}</td>
                <td>${list.sqid}</td>
                <td>
                    <c:if test="${list.type==1|| list.type=='1'}">三合一</c:if>
                    <c:if test="${list.type==2|| list.type=='2'}">出租屋</c:if>
                    <c:if test="${list.type==3|| list.type=='3'}">电瓶车</c:if>
                </td>
                <td>
                    <c:if test="${list.status eq '1'}">待审核</c:if>
                    <c:if test="${list.status eq '2'}">流转中</c:if>
                    <c:if test="${list.status eq '3'}">处理中</c:if>
                    <c:if test="${list.status eq '4'}">待反馈</c:if>
                    <c:if test="${list.status eq '5'}">区确认</c:if>
                    <c:if test="${list.status eq '6'}">待确认</c:if>
                    <c:if test="${list.status eq '7'}">街道确认</c:if>
                    <c:if test="${list.status eq '8'}">退回反馈</c:if>
                    <c:if test="${list.status eq '9'}">已退回</c:if>
                </td>
                <td>
                    &nbsp;
                    <a href="<c:url value='/danger/info/detail'/>?id=${list.id}" target="dialog" mask="true" resizable="false"
                       width="600" height="600" title="查看详情" rel="page_info_detail">查看详情&nbsp;</a>
                </td>
            </tr>
        </c:forEach>
        </tbody>
    </table>
    <div class="panelBar">
        <div class="pages">
            <span>显示</span>
            <select class="combox" name="numPerPage" onchange="navTabPageBreak({numPerPage:this.value})">
                <option value="20" <c:if test="${pager.numPerPage ==20}" >selected="selected"</c:if>>20</option>
                <option value="50" <c:if test="${pager.numPerPage ==50}" >selected="selected"</c:if>>50</option>
                <option value="100" <c:if test="${pager.numPerPage ==100}" >selected="selected"</c:if>>100</option>
                <option value="200" <c:if test="${pager.numPerPage ==200}" >selected="selected"</c:if>>200</option>
            </select>
            <span>条，共${pager.total}条</span>
        </div>
        <div class="pagination" targetType="navTab" totalCount="${pager.total}" numPerPage="${pager.numPerPage}" pageNumShown="10" currentPage="${pager.pageNum}"></div>
    </div>
    <form id="pagerForm" method="post" action="<c:url value='/danger/info/list'/>">
        <input type="hidden" name="pageNum" value="${pager.pageNum}"/>
        <input type="hidden" name="numPerPage" value="${pager.numPerPage}"/>
        <input type="hidden" name="orderField" value="${query.orderField}"/>
        <input type="hidden" name="orderDirection" value="${query.orderDirection}"/>
        <input type="hidden" name="start" value="<fmt:formatDate value="${query.start}" pattern="yyyy-MM-dd"/>"/>
        <input type="hidden" name="end" value="<fmt:formatDate value="${query.end}" pattern="yyyy-MM-dd"/>"/>
        <input type="hidden" name="fjid" id="fjid" value="${query.data.fjid}"/>
        <input type="hidden" name="pcsid" id="pcsid" value="${query.data.pcsid}"/>
        <input type="hidden" name="sqid" id="sqid" value="${query.data.sqid}"/>
        <input type="hidden" name="yhlb" value="${query.data.yhlb}"/>
        <input type="hidden" name="status" value="${query.data.status}"/>
    </form>
</div>
<script type="text/javascript">
function setSelVal(id,value){
    $(id).val(value);
}
</script>
